package io.persimmon.core.module.collection;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

public class ListValueMap<K, T> extends HashMap<K, List<T>> {
    public void add(K key, T value) {
        List<T> list = this.computeIfAbsent(key, k -> new ArrayList<>());
        list.add(value);
    }
}
